package com.sinosoft.bee.services.consumer.demo.config;

import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.cloud.netflix.ribbon.RibbonClient;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;

/**
 * @author:TobbyQuinn
 * @date:2018/4/24
 * @project:bee
 **/
@Configuration
public class RestConfig {
    /**
     * 默认即为客户端轮询策略
     * @return
     */
    @Bean
    @LoadBalanced
    public RestTemplate restTemplate(){
        return new RestTemplate();
    }


}
